package com.xframe.xdal.config;

import com.xframe.xdal.core.constant.DataSourceTypeEnums;
import com.xframe.xdal.core.constant.DbManageConstants;


/**
 * 功能描述:表示一个数据源构建对象
 *
 * @author xufeng
 * @version 1.0
 * @date 2022-09-26
 */
public class DataSourceConfig implements IDataSourceConfig{

    /**
     * 数据源名称
     */
    private String dataSourceName;
    /**
     * 数据源类型
     */
    private DataSourceTypeEnums dataSourceTypeName;

    /**
     * 数据源主机名
     */
    private String host = "127.0.0.1";
    /**
     * 端口号
     */
    private Integer port = 3306;
    /**
     * 用户名
     */
    private String username = "root";
    /**
     * 密码
     */
    private String password;
    /**
     * 数据库名称
     */
    private String databaseName;
    /**
     * SQLSERVER使用 架构名称
     */
    private String schema = DbManageConstants.SQLSERVER_DBO;

    @Override
    public String getDataSourceName() {
        return dataSourceName;
    }

    public void setDataSourceName(String dataSourceName) {
        this.dataSourceName = dataSourceName;
    }

    @Override
    public DataSourceTypeEnums getDataSourceTypeName() {
        return dataSourceTypeName;
    }

    public void setDataSourceTypeName(DataSourceTypeEnums dataSourceType) {
        this.dataSourceTypeName = dataSourceType;
    }

    @Override
    public String getHost() {
        return host;
    }

    public void setHost(String host) {
        this.host = host;
    }

    @Override
    public Integer getPort() {
        return port;
    }

    public void setPort(Integer port) {
        this.port = port;
    }

    @Override
    public String getUsername() {
        return username;
    }

    public void setUsername(String username) {
        this.username = username;
    }

    @Override
    public String getPassword() {
        return password;
    }

    public void setPassword(String password) {
        this.password = password;
    }

    @Override
    public String getDatabaseName() {
        return databaseName;
    }

    public void setDatabaseName(String databaseName) {
        this.databaseName = databaseName;
    }

    @Override
    public String getSchema() {
        return schema;
    }

    public void setSchema(String schema) {
        this.schema = schema;
    }
}
